-- element_burn
-- created by panyl
-- 元素球燃烧

return {
    apply = function(prop, baseValue)
        return prop[3];
    end,

    record = function(target, prop, path)
        return false;
    end,

    trigger = function(who, prop, target)
        local damage = math.floor(tonumber(prop[3]) * who:queryAttrib("magic") / 1000);
        local end_round = CombatM.getRound() + 2;

        local condition = {
            ["prop"] = { PropM.getPropId("burn"), 1, damage, end_round, },
            ["end_round"] = end_round,
        };

        CombatStatusM.applyStatus(target, "burn", condition);

        return true;
    end
};
